package com.schedule.service;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.schedule.dao.MessageMapper;
import com.schedule.entity.Message;
import com.schedule.entity.Schedule;

@Service
public class MessageServiceImpI implements MessageService {
	@Autowired
	MessageMapper messageMapper;

	public void AddMessage(Message message) {
		messageMapper.AddMessage(message);

	}

	public List<Message> SelectMessage(String user) {
		
		return messageMapper.SelectMessage(user);
	}

	public void ShareSchedule(Schedule schedule) {
		messageMapper.ShareSchedule(schedule);
		
	}

	public List<Message> SelectRequestMessage(String user) {
		
		return messageMapper.SelectRequestMessage(user);
	}

	public void DeleteMsg(Message message) {
		messageMapper.DeleteMsg(message);
		
	}

}
